package com.dgut.epidemic.mapper;

import com.dgut.epidemic.pojo.Daily_data;
import com.dgut.epidemic.pojo.WeChatUser;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Author: wuhaoduan
 * Date: 2021/6/6 10:10
 */
@Mapper
@Repository
public interface WeChatUserMapper {
    //判断账号密码是否正确
    int judgeWeChatUser(String id,String password);

    //根据id获得用户数据
    WeChatUser getWeChatUserById(String id);

    //判断某人当天是否已经上报
    int judgeUserIsSubmit(String id);

    //提交每日疫情填报
    void insertDailyData(Daily_data daily_data);

    //用户填报次数+1
    void updateUserCount(String id);

    //判断某人昨天是否以及上报
    int judgeUserIsSubmitYes(String id);

    //用户填报次数置为x
    void updateUserCountChange(int x,String id);

    //获得所有用户
    List<WeChatUser> getAllWeChatUser();
}
